<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>

<h2>
    <c:out value="${album.name}"/>
</h2>
<c:out value="Artist:"/>
<a href="<c:url value="/getArtist?artistId=${artist.id}"/>"><c:out value="${artist.name}"/></a>
<br/>
<c:out value="Year: ${album.year}"/>
<br/>
<br/>
<c:out value="${album.description}"/>
<br/>
<br/>
<img src="${pageContext.request.contextPath}/img/albums/${album.id}.jpg"/>
<h2>Tracks</h2>
<table>
    <tr>
        <td align="right">
            #
        </td>
        <td>
            Title
        </td>
        <td>
            Length
        </td>
    </tr>
    <c:forEach var="track" items="${tracks}">
        <tr>
            <td align="right">
                <c:out value="${track.number}"/>
            </td>
            <td>
                <c:out value="${track.name}"/>
            </td>
            <td align="center">
                <c:out value="${track.length}"/>
            </td>
        </tr>
    </c:forEach>
</table>
<br>
<a href="<c:url value="/home"/>">Home</a>